import { EChartsOption } from "echarts";

export const mapOpts: EChartsOption = {
    color: ["#012746"],
    visualMap: {
        max: 6,
        min: 0,
        left: "right",
        inRange: {
            color: ["#012746", "#2763A4", "#6AA8EE"],
        },
        textStyle: {
            color: "#fff",
        },
        
    },
    tooltip: {
        trigger: "item",
        showDelay: 0,
        transitionDuration: 0.2,
        
    },
    series: [
        {
            type: "map",
            map: "jxhjxy",
            name: "学校",
            label: {
                show: true,
                color: "#fff",
            },
            itemStyle: {
                areaColor: "transparent",
                borderColor: "#2763A4",
                borderWidth: 1,
            },
            data: [
                { name: "16栋", value: 2 },
                { name: "17栋", value: 1 },
                { name: "18栋", value: 1 },
                { name: "19栋", value: 0 },
                { name: "20栋", value: 0 },
                { name: "24栋", value: 0 },
                { name: "产教融合大楼", value: 6 },
                { name: "林业大棚", value: 1 },
                { name: "园林温室大棚", value: 0 },
                { name: "风雨球场", value: 0 },
            ],
        },
    ],
    title: {
        textStyle: {
            color: "#fff",
        },
        text: "学校设备分布",
        subtext: "Data from jxhjxy",
        left: "center",
        top: "top",
    },
};
